cmake_minimum_required (VERSION 3.5)

set(prjname cmake_demo)
# 工程名
project(${prjname})

# 输出目录
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY  ${CMAKE_SOURCE_DIR}/make/out/${CMAKE_BUILD_TYPE})

aux_source_directory(. src)
 
# 将源代码添加到此项目的可执行文件。
add_executable (${prjname} ${src})

# 设置链接库文件
target_link_libraries(${prjname} glad.lib glfw.lib)

# 拷贝文件
file(COPY ${3rdbase}/glad/bin/glad.dll DESTINATION ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})
file(COPY ${3rdbase}/glfw/bin/glfw.dll DESTINATION ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})